package com.ezmobo.dao.Student;

import java.util.List;

import org.mybatis.spring.support.SqlSessionDaoSupport;

//public class AdminDao extends DynamicSqlSessionDaoSupport implements AdminUserMapper {
public class StudentDao extends SqlSessionDaoSupport implements StudentMapper {

	@Override
	public List<StudentDO> getStudents() {
		return this.getSqlSession().selectList("com.ezmobo.dao.Student.getStudents");
	}

	@Override
	public int addStudent(StudentDO student) {
		return this.getSqlSession().insert("com.ezmobo.dao.Student.addStudent", student);
	}

	@Override
	public int deleteStudent(String name) {
		return this.getSqlSession().delete("com.ezmobo.dao.Student.deleteStudent", name);
	}

	@Override
	public int updateStudent(StudentDO student) {
		return this.getSqlSession().update("com.ezmobo.dao.Student.updateStudent", student);
	}

}
